﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="template.aspx.cs" Inherits="Widgets_Mail_Email_template" %>
<div class="widget_header_main">
<table border="0" cellspacing="0" cellpadding="3" width="100%" class="widget_header_tbl">
<tbody>
   <tr valign="top" class="widget_header_tbl">
      <td width="80%" class="widget_header" id="wdivh{0}">
         <img src="[img]" id="wimg{0}" border="0" />
         <span id="wdivht{0}">[title]</span>
         <input type="text" id="wdivhi{0}" class="widget_title_input" style="display:none" />
      </td>
      <td width="20%" align="right">
         <a id="wdivca{0}" onmouseout="collapse('wdivcd{0}')"><div id="wdivcad{0}" class="MenuCmd"></div></a>
      </td>
   </tr>
</tbody>
</table>
</div>
<style>
.WSettings_Tab_S
{
   padding: 2px;
   border-left: solid 1px black;
   border-right: solid 1px black;
   border-top: solid 1px black;   
   cursor: pointer;
   font-weight:bold;
}
.WSettings_Tab
{
   padding: 2px;
   border: solid 1px black;
   cursor: pointer;
}
.WSettings_S
{
   background: #abcdef;   
}
.WMessage
{
   background: #abcdef;
   padding: 2px;
   margin: 1px;
   border: solid 1px black;
}

.WMessage_Over
{
   background: #aaaaaa;
   padding: 2px;
   margin: 1px;
   border: solid 1px black;
}
</style>
<div class="widget_body" id="wdivb{0}" style="overflow:auto;">
<div id="wdivbs{0}" style="display:none;">
<!-- Settings Area -->
<table border="0" width="100%" cellspacing="0" cellpadding="0">
<tr valign="top" align="center">
   <td id="wt_Settings{0}" width="50%" class="WSettings_Tab_S" onclick="$WI({0}).ShowSettings()">Settings</td>
   <td id="wt_Preferences{0}" width="50%" class="WSettings_Tab" onclick="$WI({0}).ShowPreferences()">Preferences</td>
</tr>
<tr><td colspan="2" class="WSettings_S" style="border-left: solid 1px black;border-right: solid 1px black;border-bottom: solid 1px black;">
<div id="ws_Settings{0}">
<table border="0">
<tr><td>Mail</td><td>:</td><td><select onchange="$WI({0}).Client_ChangeMailServer()" id="ws_Mail{0}"><option value="nus">NUS Exchange</option><option value="gmail">Gmail</option><option value="o">Others</option></select></td></tr>
<tr valign="top"><td>* IMAP Server</td><td>:</td><td><input type="text" id="ws_IMAP{0}" /><br /><input id="ws_IMAP_Secure{0}" type="checkbox" name="ws_IMAP_Secure{0}"/><label for="ws_IMAP_Secure{0}">Require Secure Connection</label></td></tr>
<tr valign="top"><td>* SMTP Server</td><td>:</td><td><input type="text" id="ws_SMTP{0}" />
<br /><input id="ws_SMTP_Secure{0}" type="checkbox" name="ws_SMTP_Secure{0}"/><label for="ws_SMTP_Secure{0}">Require Secure Connection</label>
<br /><input id="ws_SMTP_RequireLogin{0}" type="checkbox" name="ws_SMTP_RequireLogin{0}"/><label for="ws_SMTP_RequireLogin{0}">Requires Login</label>
</td></tr>
<tr><td>* Email Address</td><td>:</td><td><input type="text" id="ws_EmailFrom{0}" /></td></tr>
<tr><td>* UserID</td><td>:</td><td><input type="text" id="ws_UserID{0}" /></td></tr>
<tr><td>* Password</td><td>:</td><td><input type="password" id="ws_Password{0}" title="Security Notification: The password is encrypted using a one off 1024-bit RSA key before sending to the server" /><br />
<!--
<input type="checkbox" id="ws_PasswordSave{0}" checked />
<label for="ws_PasswordSave{0}">Save Password on Server</label>
-->
</td></tr>
</table>
</div>
<div id="ws_Preferences{0}">
<table border="0">
<tr>
   <td>Title</td>
   <td>:</td>
   <td><input type="text" id="ws_Title{0}" /></td>
</tr>
<tr>
   <td>Height</td>
   <td>:</td>
   <td><input type="text" id="ws_Height{0}" />
   <br /><i>Put as 0 for auto resize</i>
   </td>
</tr>
</table>
</div>
</td></tr>
</table>
<input type="button" class="btn" onclick="$WI({0}).Save();return false;" value="Save" id="btn_Save{0}" />
<input type="button" class="btn" onclick="$WI({0}).Edit();return false;" value="Cancel" />
</div>

<div id="wdivbc{0}">
<!-- Content Area -->
<div id="wdiv_Ajax{0}"><img src="/images/ajax_bar.gif" border="0" /></div>

<div id="wdiv_Grid{0}" style="display:none">
</div>
<div id="wdiv_Msg{0}" style="display:none">
<table border="0" width="100%">
<tr><td width="2%">From</td><td width="1%">:</td><td width="97%" id="tr_MsgFrom{0}"></td></tr>
<tr><td>Subject</td><td>:</td><td id="tr_MsgSubj{0}"></td></tr>
<tr><td colspan="3" id="tr_MsgBody{0}"></td>
</table>
<input type="button" onclick="$hide('wdiv_Msg{0}');$show('wdivbc{0}');" value="< Back" />
<input type="button" id="btn_MsgReply{0}" value="Reply" />
</div>

<div id="wdiv_Reply{0}" style="display:none">
<table border="0" width="100%">
<tr><td width="2%">To</td><td width="1%">:</td><td width="97%"><input type="text" id="wdiv_ReplyTo{0}" style="width:95%" /></td></tr>
<tr><td>Subject</td><td>:</td><td><input type="text" id="wdiv_ReplySubject{0}" style="width:95%" /></td></tr>
<tr><td colspan="3">
<textarea id="wdiv_ReplyBody{0}" rows="20" style="width:95%"></textarea>
</td>
</table>
<input type="button" onclick="$hide('wdiv_Reply{0}');$show('wdivbc{0}');" value="< Back to Messages" />
<input type="button" onclick="$WI({0}).Send();" value="Send Email" />
</table>

</div>
<span id="lbl_Status{0}"></span>

</div>

</div>
<div class="widget_footer">
<table border="0" width="100%">
<tbody>
<tr valign="top">
   <td width="*"><div class="widget_footer_collapse" id="wdivf{0}" onclick="W{0}.instance.ToggleExpand();"></div></td>
   <td align="right" width="14px"><div class="widget_heighthandle" id="wdivhh{0}" onmousedown="Q_Drag.start(event, 'resize_y', 'wdivb{0}', {0});return false;"></td>
</tr>
</tbody>
</table>
</div>

<!-- MENU -->
<div class="DropDownMenu" id="wdivcd{0}" onmouseover="cancelcollapse()" onmouseout="collapse('wdivcad{0}')">
<ul class='DDMenu' id="wdivc{0}">
   <li><a onclick="$WI({0}).TitleEdit();collapseMenu('wdivcad{0}');">Edit Widget Title</a></li>
   <li><a onclick="$WI({0}).Edit();collapseMenu('wdivcad{0}');" id="wdivc_edit{0}">Edit Widget Properties</a></li>   
   <li><a onclick="$WI({0}).Refresh();collapseMenu('wdivcad{0}');">Refresh Mail</a></li>   
   <li><a onclick="$WI({0}).Delete();collapseMenu('wdivcad{0}');">Delete Widget</a></li>
   <li><a onclick="$WI({0}).ToggleExpand();collapseMenu('wdivcad{0}');">Toggle Size</a></li>
</ul>
</div>